package com.ccb.sc.goods.convert;

import com.ccb.sc.goods.vo.AppGoodsSpecsVo;
import com.ccb.sc.goods.vo.AppGoodsVo;
import com.ccb.sc.common.modules.goods.entity.Goods;
import com.ccb.sc.common.modules.goods.entity.GoodsSpecs;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

import java.util.List;

/**
 * @author ken
 * @version 1.0
 * @date 2020-09-20
 */
@Mapper
public interface AppGoodsConvert {

    AppGoodsConvert INSTANCE = Mappers.getMapper(AppGoodsConvert.class);

    AppGoodsVo entity2Vo(Goods entity);

    List<AppGoodsSpecsVo> goodsSpec2VoBatch(List<GoodsSpecs> specs);
}
